var players_L2 = [];
var players_L3 = [];

function show_honor(){
     $.ajax({
        type:"POST",
        url:"http://47.75.143.53:3001/",
        dataType:"json",
        success:function(data){

            $(".govinda").html("");
            $(".advanced").html("");
            $(".L3").text("共"+data['pioneer_info'][1].length+"位选手");
            $(".L2").text("共"+data['pioneer_info'][0].length+"位选手");
            for(var i = 0;i<data['pioneer_info'][1].length;i++){
                var govinda_player = $("<tr class=\"\">\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t<td class=\"number_3bb\">"+(i+1)+"</td>\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t<td class=\"name_28M\">\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t\t<div><span class=\"name_28M\">"+data['pioneer_info'][1][i]['name']+"</span><span><span class=\"highlight_3Ey\">隶属战队：</span><span>"+data['pioneer_info'][1][i]['team_name']+"</span></span></div><span\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t\t class=\"highlight_3Ey\">签名档：</span>这个人很懒，什么话也没有留下。\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t</td>\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t<td class=\"score_3gA\">+"+data['pioneer_info'][1][i]['reward_score']+"</td>\n" +
                "\t\t\t\t\t\t\t\t\t\t\t</tr>");
                $(".govinda").append(govinda_player);
            }

            for(var i = 0;i<data['pioneer_info'][0].length;i++){
                var advanced_player = $("<tr class=\"\">\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t<td class=\"number_3bb\">"+(i+1)+"</td>\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t<td class=\"name_28M\">\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t\t<div><span class=\"name_28M\">"+data['pioneer_info'][0][i]['name']+"</span><span><span class=\"highlight_3Ey\">隶属战队：</span><span>"+data['pioneer_info'][0][i]['team_name']+"</span></span></div><span\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t\t class=\"highlight_3Ey\">签名档：</span>这个人很懒，什么话也没有留下。\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t</td>\n" +
                "\t\t\t\t\t\t\t\t\t\t\t\t<td class=\"score_3gA\">+"+data['pioneer_info'][0][i]['reward_score']+"</td>\n" +
                "\t\t\t\t\t\t\t\t\t\t\t</tr>");
                $(".advanced").append(advanced_player);
            }
        }
    })
}

$(function(){

    show_honor();

    $(".rocket_2NN").click(function(){
        $('body,html').animate({scrollTop: 0},500);
        return false;
    })
})